# Maintainer: Anatol Pomozov <anatol.pomozov@gmail.com>

_gemname=webrick
pkgname=ruby-$_gemname
pkgver=1.8.1
pkgrel=1
pkgdesc='An HTTP server toolkit that can be configured as an HTTPS server'
arch=(any)
url='https://github.com/ruby/webrick'
license=(BSD-2)
depends=(ruby)
options=(!emptydirs)
source=(https://rubygems.org/downloads/$_gemname-$pkgver.gem)
noextract=($_gemname-$pkgver.gem)
sha256sums=('19411ec6912911fd3df13559110127ea2badd0c035f7762873f58afc803e158f')

package() {
  local _gemdir="$(ruby -e'puts Gem.default_dir')"
  gem install --no-document --ignore-dependencies --no-user-install -i "$pkgdir/$_gemdir" -n "$pkgdir/usr/bin" $_gemname-$pkgver.gem
  rm "$pkgdir/$_gemdir/cache/$_gemname-$pkgver.gem"
}
